#!/usr/bin/python
# -*- coding: utf-8 -*-
# File: namespaces.py
# Author: Tomás Vírseda
# License: GPL v3
# Description:  Namespaces

# Firstly borrowed from SWAML project

"""Common namespaces"""

from rdflib import Namespace

# W3C Ontologies
RDF = Namespace(u'http://www.w3.org/1999/02/22-rdf-syntax-ns#')
RDFS = Namespace(u'http://www.w3.org/2000/01/rdf-schema#')

# Dublin Core
DC = Namespace(u'http://purl.org/dc/elements/1.1/')
DCTERMS = Namespace(u'http://purl.org/dc/terms/')

# NEPOMUK Ontologies
# NEPOMUK Personal Information Model
PIMO = Namespace(u'http://www.semanticdesktop.org/ontologies/pimo/')

# NEPOMUK Annotation Ontology
NAO = Namespace(u'http://www.semanticdesktop.org/ontologies/nao/')

# NEPOMUK Information Element Ontology
NIE = Namespace(u'http://www.semanticdesktop.org/ontologies/nie/')

# NEPOMUK File Ontology
NFO = Namespace(u'http://www.semanticdesktop.org/ontologies/nfo/')

# Others
FOAF = Namespace(u'http://xmlns.com/foaf/0.1/') # Friend Of A Friend
SIOC  = Namespace(u"http://rdfs.org/sioc/ns#")
SIOCT = Namespace(u"http://rdfs.org/sioc/types#")
GEO   = Namespace(u"http://www.w3.org/2003/01/geo/wgs84_pos#")
MVCB  = Namespace(u"http://webns.net/mvcb/")
ICAL  = Namespace(u"http://www.w3.org/2002/12/cal/icaltzd#")
XSD   = Namespace(u"http://www.w3.org/2001/XMLSchema#")

NSBINDINGS = {
    u"rdf"   : RDF,
    u"rdfs"  : RDFS,
    u"pimo"  : PIMO,
    u"nao"   : NAO,
    u"nfo"   : NFO,
    u"nie"   : NIE,
    u"dc"    : DC,
    u"dct"   : DCTERMS,
    u"foaf"  : FOAF,
    u"sioc"  : SIOC,
    u"sioct" : SIOCT,
    u"geo"   : GEO,
    u"mvcb"  : MVCB,
    u"ical"  : ICAL,
    u"xsd"   : XSD
}

"""
keyword['LIBEXTRACTOR KEYWORD-TYPE'] = (
    'DC-ELEMENT',
    'DC-TERM',
    'NEPOMUK-ONTOLOGY',         # left part predicate
    'NEPOMUK-CLASS/PROPERTY'    # right part predicate
)
"""
EXTRACTOR_KEYWORD = {}
EXTRACTOR_KEYWORD['album'] = ('type', 'collection', 'pimo', 'Collection')
EXTRACTOR_KEYWORD['artist'] = ('creator', '', 'nao', 'creator')
EXTRACTOR_KEYWORD['book title'] = ('title', '', 'nie', 'title')
EXTRACTOR_KEYWORD['author'] = ('creator', '', 'nao', 'creator')
EXTRACTOR_KEYWORD['creator'] = ('creator', '', 'nao', 'creator')
EXTRACTOR_KEYWORD['creation date'] = ('date', '', 'nie', 'created')
EXTRACTOR_KEYWORD['date'] = ('date', '', 'nie', 'contentLastModified')
EXTRACTOR_KEYWORD['description'] = ('description', '', 'nao', 'creator')
EXTRACTOR_KEYWORD['generator'] = ('format', 'Software', 'nie', 'generator')
EXTRACTOR_KEYWORD['keywords'] = ('subject', '', 'nao', 'hasTag')
EXTRACTOR_KEYWORD['language'] = ('language', '', 'nie', 'language')
EXTRACTOR_KEYWORD['page count'] = ('format', '', 'nfo', 'pageCount')
EXTRACTOR_KEYWORD['producer'] = ('format', 'Software', 'nie', 'generator')
EXTRACTOR_KEYWORD['software'] = ('format', 'Software', 'nie', 'generator')
EXTRACTOR_KEYWORD['subject'] = ('subject', '', 'nie', 'subject')
EXTRACTOR_KEYWORD['title'] = ('title', '', 'nie', 'title')
#paragraph count
#line count
#word count
#page count
#character count - 817
#last saved by
#revision history
